<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta
      name="viewport"
      content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <script src="https://unpkg.com/react@17/umd/react.development.js"></script>
  <script src="https://unpkg.com/react-dom@17/umd/react-dom.development.js"></script>
  <script src="https://unpkg.com/babel-standalone@6/babel.min.js"></script>

  <body>
    <div id="root"></div>
    <script type="text/babel">
      class Persons {
        constructor(x, y) {
          this.x = x
          this.y = y
        }
        add() {
          console.log(this.x + this.y)
          console.log(this, 'this')
        }
      }
      const a = new Persons(1, 2)
      const b = new Persons(3, 4)
      console.log(a.constructor, 'a')
      console.log(b, 'b')
      a.add()
      b.add()
    </script>
  </body>
</html>
